package com.zzg.controller;

import com.zzg.entity.ShowMap;
import com.zzg.service.ShowMapService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 * @author zzg
 * @version 1.0.0
 * @ClassName：ShowMapController
 * @Description: 描述
 * @date 2021/7/20
 **/
@Controller
public class ShowMapController {
    @Autowired
    private ShowMapService showMapService;

    @RequestMapping(value = "/ShowMap",produces = "application/json;charset=utf-8")
    @ResponseBody
    public List<ShowMap> showMap(){
        return showMapService.selectMap();
    }
    @RequestMapping(value = "/DriverMap",produces = "application/json;charset=utf-8")
    @ResponseBody
    public List<ShowMap> driverMap(String mapId){
        System.out.println("mapId:"+mapId);
        return showMapService.driverMap(mapId);
    }


}
